Up to now, as described in the following Patent Document 1 and Patent Document 2, for example, a pilot operated switching valve constructed such that a valve member for opening and closing a valve seat in a flow path is driven by a piston operated by the action of a pilot fluid pressure is publicly known. In such a switching valve, although not described in the above documents in particular, a magnet and magnetic sensors are used to detect the operational position of the valve member and the operational position of the valve member is indirectly detected by detecting the operational position of the piston. That is, the magnet is attached to the piston, the magnetic sensors are attached to the housing of the switching valve, and the operational position of the piston is detected by the magnet and the magnetic sensors.
Then, as a method for attachment of the magnetic sensors to the housing, generally, as shown in FIG. 7, two attachment grooves 101 and 101 are formed in parallel on the side face of the housing, magnetic sensors 102a and 102b are attached at different positions from each other in the direction of the coaxial line, one magnetic sensor 102a detects the position where the piston reaches a valve closing position, and the other magnetic sensor 102b detects the piston where the piston reaches a valve opening position. These positional detection signals are input to a control system and the signals are used as a control signal.
Patent Document 1: Japanese Unexamined Patent Application Publication No. 2001-193845
Patent Document 2: Japanese Unexamined Patent Application Publication No. 2001-193846
Then, in the conventional switching valve, the two attachment grooves 101 and 101 are formed over the whole length on the side face of the housing so as to have the same length and the magnetic sensors 102a and 102b are attached therein such that the position of the magnetic sensors 102a and 102b is displaced from each other so as to be able to detect the valve closing position and the valve opening position. However, since it is difficult to find the positioning target, it is troublesome, and, in addition, it was easy to make an error of attaching the magnetic sensor for detection of the valve closing position and the magnetic sensor for detection of the valve opening position to opposite positions.